# -*- coding: utf8 -*-
import json
from aliyunsdkcore.client import AcsClient
from aliyunsdkcore.acs_exception.exceptions import ClientException
from aliyunsdkcore.acs_exception.exceptions import ServerException
from aliyunsdknlp_automl.request.v20191111 import RunPreTrainServiceRequest
# Initialize AcsClient instance
client = AcsClient(
  "LTAI5tQuVNdyxzuHKuVDtKoU",
  "g2ADtEsn6UjPA2Ab4fz0agremAkXCY",
  "cn-hangzhou"
);
content = '牡丹江市阳明区2021年高标准农田建设项目勘察设计（一标段）中标候选人公示'
# Initialize a request and set parameters
request = RunPreTrainServiceRequest.RunPreTrainServiceRequest()
request.set_ServiceName('classify-type-bid')
request.set_PredictContent(content)
# Print response
response = client.do_action_with_exception(request)
resp_obj = json.loads(response)
predict_result = json.loads(resp_obj['PredictResult'])
print(predict_result)